|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
XoFactory is responsible for loading an XoDMInstance object from an XML file,
or creating it from scratch, provided the Registry has appropriate definitions and/or
a specific XML processing instruction included in the parsed file gives the Data-Model definition file location.
For loading or creating DM instance, init options can be specified. These options override those
possibly specified in the root element's Data-Model definition. Valid options are :
XoConstants.INIT_READ_ONLY, with value "true" or "false", as string or BooleanXoConstants.INIT_REQUESTABLE, with value "true" or "false" as string or Boolean (note that this option
can not be changed after DM instance creation, and default value is true),XoConstants.INIT_HISTORY_SIZE, with integer value as string or IntegerXoConstants.INIT_DMD_AUTO_LOADING_ENABLED, to tell with a Boolean or string to this factory if it can take care of PI describing
DM modules locations and load them if needeed during XML file parsing.
| Method Summary | |
XoDMInstance |
createDMInstance(java.lang.String rootnsref,
java.lang.String rootnsprefix,
java.lang.String rootelement,
java.util.Map options,
java.lang.Object initObject)
Creates a new DM instance with param rootelement as root element name,
from namespace param rootnsref, with param rootnsprefix as optional prefix. |
XoDMInstance |
createDMInstance(XoRoot root,
java.lang.String rootnsprefix,
java.util.Map options,
java.lang.Object initObject)
Creates a new DM instance with param root as root element and param rootnsprefix
as optional prefix. |
XoDMInstance |
loadDMInstance(java.io.InputStream is,
java.util.Map options,
java.lang.Object initObject)
Loads a DM instance from an XML document read by param reader. |
XoDMInstance |
loadDMInstance(java.io.Reader r,
java.util.Map options,
java.lang.Object initObject)
Loads a DM instance from an XML document read by param reader. |
XoDMInstance |
loadDMInstance(java.lang.String xmlDoc,
java.util.Map options,
java.lang.Object initObject)
Loads a DM instance from a String argument ( xmlDoc) containing an XML document. |
XoDMInstance |
loadDMInstance(java.net.URL url,
java.util.Map options,
java.lang.Object initObject)
Loads a DM instance from an XML file pointed by param url. |
| Method Detail |
public XoDMInstance loadDMInstance(java.net.URL url,
java.util.Map options,
java.lang.Object initObject)
throws XoException
url.
url - URL of XML file.options - a map containing valid init options, this argument can be nullinitObject - an object that can be passed to root element by method XoRoot.xoInitialize(Object)
XoException - if some error occurred during parsing.
public XoDMInstance loadDMInstance(java.io.InputStream is,
java.util.Map options,
java.lang.Object initObject)
throws XoException
reader.
is - an InputStream on XML document.options - a map containing valid init options, this argument can be nullinitObject - an object that can be passed to root element by method XoRoot.xoInitialize(Object)
XoException - if some error occurred during parsing.
public XoDMInstance loadDMInstance(java.io.Reader r,
java.util.Map options,
java.lang.Object initObject)
throws XoException
reader.
r - Reader on XML document.options - a map containing valid init options, this argument can be nullinitObject - an object that can be passed to root element by method XoRoot.xoInitialize(Object)
XoException - if some error occurred during parsing.
public XoDMInstance loadDMInstance(java.lang.String xmlDoc,
java.util.Map options,
java.lang.Object initObject)
throws XoException
xmlDoc) containing an XML document. This method is a facility
method, as we could write also loadDMInstance(new StringReader(xmlDoc), options, initObject).
xmlDoc - a string containing an XML document.options - a map containing valid init options, this argument can be nullinitObject - an object that can be passed to root element by method XoRoot.xoInitialize(Object)
XoException - if some error occurred during parsing.
public XoDMInstance createDMInstance(XoRoot root,
java.lang.String rootnsprefix,
java.util.Map options,
java.lang.Object initObject)
throws XoException
root as root element and param rootnsprefix
as optional prefix.
root - the root element and its descendants if anyrootnsprefix - optional prefix for root's namespace (or empty string if no prefix)options - a map containing valid init options, this argument can be nullinitObject - an object that can be passed to root element by method XoRoot.xoInitialize(Object)
XoException - if some error occurred during creation process
public XoDMInstance createDMInstance(java.lang.String rootnsref,
java.lang.String rootnsprefix,
java.lang.String rootelement,
java.util.Map options,
java.lang.Object initObject)
throws XoException
rootelement as root element name,
from namespace param rootnsref, with param rootnsprefix as optional prefix.
rootnsref - namespace of root elementrootnsprefix - optional prefix for this namespace (or empty string if no prefix)rootelement - root element nameoptions - a map containing valid init options, this argument can be nullinitObject - an object that can be passed to root element by method XoRoot.xoInitialize(Object)
XoException - if some error occurred during creation process
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||